package com.ruoyi.activiti.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.activiti.mapper.MyHolidayMapper;
import com.ruoyi.activiti.domain.MyHoliday;
import com.ruoyi.activiti.service.IMyHolidayService;
import com.ruoyi.common.core.text.Convert;

/**
 * 工作流Service业务层处理
 * 
 * @author ldx
 * @date 2020-12-01
 */
@Service
public class MyHolidayServiceImpl implements IMyHolidayService 
{
    @Autowired
    private MyHolidayMapper myHolidayMapper;

    /**
     * 查询工作流
     * 
     * @param id 工作流ID
     * @return 工作流
     */
    @Override
    public MyHoliday selectMyHolidayById(Long id)
    {
        return myHolidayMapper.selectMyHolidayById(id);
    }

    /**
     * 查询工作流列表
     * 
     * @param myHoliday 工作流
     * @return 工作流
     */
    @Override
    public List<MyHoliday> selectMyHolidayList(MyHoliday myHoliday)
    {
        return myHolidayMapper.selectMyHolidayList(myHoliday);
    }

    /**
     * 新增工作流
     * 
     * @param myHoliday 工作流
     * @return 结果
     */
    @Override
    public int insertMyHoliday(MyHoliday myHoliday)
    {
        return myHolidayMapper.insertMyHoliday(myHoliday);
    }

    /**
     * 修改工作流
     * 
     * @param myHoliday 工作流
     * @return 结果
     */
    @Override
    public int updateMyHoliday(MyHoliday myHoliday)
    {
        return myHolidayMapper.updateMyHoliday(myHoliday);
    }

    /**
     * 删除工作流对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteMyHolidayByIds(String ids)
    {
        return myHolidayMapper.deleteMyHolidayByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除工作流信息
     * 
     * @param id 工作流ID
     * @return 结果
     */
    @Override
    public int deleteMyHolidayById(Long id)
    {
        return myHolidayMapper.deleteMyHolidayById(id);
    }
}
